<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>Kinetis Bootloader Host: blfwk::DataPacket::HexDataProducer Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="nxp_logo_small.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Kinetis Bootloader Host
   &#160;<span id="projectnumber">2.0.0</span>
   </div>
   <div id="projectbrief">Host Tools for Kinetis devices</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Introduction</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('classblfwk_1_1_data_packet_1_1_hex_data_producer.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pro-attribs">Protected Attributes</a> &#124;
<a href="classblfwk_1_1_data_packet_1_1_hex_data_producer-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">blfwk::DataPacket::HexDataProducer Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Provide data from hex string for data phase.  
 <a href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_command_8h_source.html">Command.h</a>&gt;</code></p>
<div id="dynsection-0" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
  <img id="dynsection-0-trigger" src="closed.png" alt="+"/> Inheritance diagram for blfwk::DataPacket::HexDataProducer:</div>
<div id="dynsection-0-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-0-content" class="dyncontent" style="display:none;">
<div class="center"><iframe scrolling="no" frameborder="0" src="classblfwk_1_1_data_packet_1_1_hex_data_producer__inherit__graph.svg" width="146" height="142"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
</div>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<div id="dynsection-1" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
  <img id="dynsection-1-trigger" src="closed.png" alt="+"/> Collaboration diagram for blfwk::DataPacket::HexDataProducer:</div>
<div id="dynsection-1-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-1-content" class="dyncontent" style="display:none;">
<div class="center"><iframe scrolling="no" frameborder="0" src="classblfwk_1_1_data_packet_1_1_hex_data_producer__coll__graph.svg" width="318" height="156"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
</div>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:adb7430cb76e18ef56a0b7dbff8cb85b4"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="adb7430cb76e18ef56a0b7dbff8cb85b4"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#adb7430cb76e18ef56a0b7dbff8cb85b4">HexDataProducer</a> ()</td></tr>
<tr class="memdesc:adb7430cb76e18ef56a0b7dbff8cb85b4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor. <br /></td></tr>
<tr class="separator:adb7430cb76e18ef56a0b7dbff8cb85b4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab3d48c5529a970d1f1a2f8cfaccdb711"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab3d48c5529a970d1f1a2f8cfaccdb711"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#ab3d48c5529a970d1f1a2f8cfaccdb711">HexDataProducer</a> (const uchar_vector_t &amp;data)</td></tr>
<tr class="memdesc:ab3d48c5529a970d1f1a2f8cfaccdb711"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor that takes a vector&lt;uchar&gt; parameter. <br /></td></tr>
<tr class="separator:ab3d48c5529a970d1f1a2f8cfaccdb711"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8c33f4c5805957be1f0e98be913c669b"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#a8c33f4c5805957be1f0e98be913c669b">initFromString</a> (const std::string hexData)</td></tr>
<tr class="memdesc:a8c33f4c5805957be1f0e98be913c669b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialize with a data string.  <a href="#a8c33f4c5805957be1f0e98be913c669b">More...</a><br /></td></tr>
<tr class="separator:a8c33f4c5805957be1f0e98be913c669b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a84c58653a12e725cc28d5a05abdf8f3c"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a84c58653a12e725cc28d5a05abdf8f3c"></a>
virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#a84c58653a12e725cc28d5a05abdf8f3c">~HexDataProducer</a> ()</td></tr>
<tr class="memdesc:a84c58653a12e725cc28d5a05abdf8f3c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor. <br /></td></tr>
<tr class="separator:a84c58653a12e725cc28d5a05abdf8f3c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr><td colspan="2"><div class="groupHeader">DataProducer</div></td></tr>
<tr class="memitem:acda9abb5697a5cba217d6146d546e51d"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="acda9abb5697a5cba217d6146d546e51d"></a>
virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#acda9abb5697a5cba217d6146d546e51d">hasMoreData</a> () const </td></tr>
<tr class="memdesc:acda9abb5697a5cba217d6146d546e51d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Query if more data is available. <br /></td></tr>
<tr class="separator:acda9abb5697a5cba217d6146d546e51d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3e22e6fe3b88d3bbe2205f793351aee1"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3e22e6fe3b88d3bbe2205f793351aee1"></a>
virtual uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#a3e22e6fe3b88d3bbe2205f793351aee1">getDataSize</a> () const </td></tr>
<tr class="memdesc:a3e22e6fe3b88d3bbe2205f793351aee1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Query the total size of the data. <br /></td></tr>
<tr class="separator:a3e22e6fe3b88d3bbe2205f793351aee1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acde7966dcc74e30804042678268e8265"><td class="memItemLeft" align="right" valign="top">virtual uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#acde7966dcc74e30804042678268e8265">getData</a> (uint8_t *data, uint32_t size)</td></tr>
<tr class="memdesc:acde7966dcc74e30804042678268e8265"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the next data chunk.  <a href="#acde7966dcc74e30804042678268e8265">More...</a><br /></td></tr>
<tr class="separator:acde7966dcc74e30804042678268e8265"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-attribs"></a>
Protected Attributes</h2></td></tr>
<tr class="memitem:ae7da0bf4f8d02201d25d088df93e599b"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ae7da0bf4f8d02201d25d088df93e599b"></a>
uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#ae7da0bf4f8d02201d25d088df93e599b">m_byteIndex</a></td></tr>
<tr class="memdesc:ae7da0bf4f8d02201d25d088df93e599b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Current byte index. <br /></td></tr>
<tr class="separator:ae7da0bf4f8d02201d25d088df93e599b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a289288e7735301ccc28799fba1a496a8"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a289288e7735301ccc28799fba1a496a8"></a>
uchar_vector_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#a289288e7735301ccc28799fba1a496a8">m_data</a></td></tr>
<tr class="memdesc:a289288e7735301ccc28799fba1a496a8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Data byte vector. <br /></td></tr>
<tr class="separator:a289288e7735301ccc28799fba1a496a8"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Provide data from hex string for data phase. </p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="acde7966dcc74e30804042678268e8265"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t blfwk::DataPacket::HexDataProducer::getData </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>size</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Get the next data chunk. </p>
<p>See host_command.h for documentation on this function.</p>
<p>Before calling <a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html#acde7966dcc74e30804042678268e8265" title="Get the next data chunk. ">getData()</a>, call moreData() to determine if data is available. </p>

<p>Implements <a class="el" href="classblfwk_1_1_data_packet_1_1_data_producer.html#a9108f733149baa7eb0339d009c6cf443">blfwk::DataPacket::DataProducer</a>.</p>

</div>
</div>
<a class="anchor" id="a8c33f4c5805957be1f0e98be913c669b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t blfwk::DataPacket::HexDataProducer::initFromString </td>
          <td>(</td>
          <td class="paramtype">const std::string&#160;</td>
          <td class="paramname"><em>hexData</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initialize with a data string. </p>
<p>See host_command.h for documentation on this function.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">hexData</td><td>String with hex digits surrounded by double brackets, e.g. '{{11 22 33}}', white space ignored </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Number of hex bytes parsed from the string. </dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="_command_8h_source.html">Command.h</a></li>
<li>Command.cpp</li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><b>blfwk</b></li><li class="navelem"><a class="el" href="classblfwk_1_1_data_packet.html">DataPacket</a></li><li class="navelem"><a class="el" href="classblfwk_1_1_data_packet_1_1_hex_data_producer.html">HexDataProducer</a></li>
    <li class="footer">Generated on Mon Mar 7 2016 16:49:51 for Kinetis Bootloader Host by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.11 </li>
  </ul>
</div>
</body>
</html>
